package collectionFramework.collectionsAndArrays;

import java.util.Collections;
import java.util.LinkedList;

public class MyCollectionsSort {
	public static void main(String[] args) {
		LinkedList<Integer> ll = new LinkedList<Integer>();

		ll.add(5);
		ll.add(9);
		ll.add(1);
		ll.add(3);
		ll.add(7);

		System.out.println("List : " + ll);

		Collections.sort(ll);
		System.out.println("After sort: " + ll);

		Collections.reverse(ll);
		System.out.println("Reverse sort: " + ll);
	}
}
